package chatclient.applets.canvas;

import chatclient.applets.note.Note;
import chatclient.tools.NoteContainer;
import chatclient.tools.NoteListener;

public abstract class ChatCanvas extends ImageCanvas
        implements NoteListener {

    private NoteContainer container;
    private String style;

    public ChatCanvas(NoteContainer notecontainer, String s) {
        super(null);
        container = notecontainer;
        style = s;
    }

    public NoteContainer getContainer() {
        return container;
    }

    public String getStyle() {
        return style;
    }

    @Override
    public void noteHeightChanged(Note note) {
         repaint();
    }

    @Override
    public void noteChanged(Note note) {
        repaint(container.getImageRate());
    }
         
}
